<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1.0" />
    <title>登录页面</title>

    <link rel="stylesheet" type="text/css" href="./css/bootstrap.css" />
    <link rel="stylesheet" type="text/css" href="./css/login.css" />
    <style type="text/css">
        .addonbg{
            /*透明效果*/
            background-color: rgba(255, 255, 255, 0.1);
            border:0px;
        }
        .addonbg:focus,
        .addonbg.focus {

            background-color:rgba(255, 255, 255, 0.1);
            border:0px;
        }
        .addonbg:hover {

            background-color:rgba(255, 255, 255, 0.1);
            border:0px;
        }
    </style>
    <script type="text/javascript" src="./js/jquery.js"></script>
    <script type="text/javascript" src="./js/bootstrap.js"></script>
    <script type="text/javascript" src="./js/login.js"></script>
    <script type="text/javascript" src="./js/cookie_util.js"></script>
    <script type="text/javascript" src="./js/app.js"></script>
    <script type="text/javascript" src="./js/controllers.js"></script>
    <script type="text/javascript" src="./js/services.js"></script>
    <script type="text/javascript">
        $(function(){

            $('[data-toggle="popover"]').popover();

            $(".addonbg").click(function(){
                showRem();
            });

            //登录
            var name=getCookie("remembername");
            var remember=getCookie("remember");
            document.getElementById("rememberme").checked=remember;
            if(name!=null||password!=null){
                $("#username").val(name);
            }
            $("#form1").submit(login);

        });
        function showRem(){
            //alert($("#rememberme").attr("checked"));
            alert(document.getElementById("rememberme").checked);
        }
    </script>
</head>

<body>
<div class="box">
    <div class="login-box">
        <div class="login-title text-center">
            <h1><small>登录</small></h1>
        </div>
        <div class="login-content ">
            <div class="form" >
                <form  method="post" id="form1">
                    <div class="form-group">
                        <div class="col-xs-12  ">
                            <div class="input-group">
                                <span class="input-group-addon"><span class="glyphicon glyphicon-user"></span></span>
                                <input type="text" id="username" name="username" class="form-control" placeholder="用户名">
							<span class="input-group-btn">
                             <button class="btn btn-default addonbg" type="button"
                                     ><span class="glyphicon glyphicon-question-sign"></span></button>
                            </span>
                                <!--  <span class="input-group-addon addonbg"><span class="glyphicon glyphicon-question-sign"></span></span>-->
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <div class="col-xs-12  ">
                            <div class="input-group">
                                <span class="input-group-addon"><span class="glyphicon glyphicon-lock"></span></span>
                                <input type="password" id="password" name="password" class="form-control" placeholder="密码" autocomplete="off">
							<span class="input-group-btn">
                             <button class="btn btn-default addonbg" type="button"
                                     ><span class="glyphicon glyphicon-question-sign"></span></button>
                            </span>
                                <!--
                                <span class="input-group-addon addonbg"><span class="glyphicon glyphicon-question-sign"></span></span>
                                -->
                            </div>

                        </div>
                    </div>
                    <div class="form-group form-actions">
                        <div class="col-xs-4 col-xs-offset-4 ">
                            <button type="submit" class="btn btn-sm btn-info"><span class="glyphicon glyphicon-off"></span> 登录</button>
                        </div>
                    </div>
                    <div class="form-group">
                        <div class="col-xs-6 link">
                            <!--
                                <p class="text-center remove-margin"><small>忘记密码？</small> <a href="javascript:void(0)" ><small>找回</small></a>
                                </p>
                                -->
                            <p class="text-center remove-margin">
                                <input type="checkbox" value="remember-me" id="rememberme"> 记住我
                            </p>

                        </div>
                        <div class="col-xs-6 link">
                            <p class="text-center remove-margin"><small>还没注册?点击这里</small> <a href="regist.html" ><small>注册</small></a>
                            </p>
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>
</body>

</html>